<?php

$query_array=array("name"=>array("name"=>__("Report"),
                                 "sql"=>"SELECT `system_name` FROM `system` WHERE `system_uuid` = '" . $_GET["pc"] . "'",
                                ),
                   "views"=>array("system"=>array(
                                                    "headline"=>__("System"),
                                                    "sql"=>"SELECT * FROM system WHERE system_uuid = '" . $pc . "' OR system_name = '" . $pc . "' ",
//                                                    "image"=>"images/os_l.png",
                                                    "fields"=>array("10"=>array("name"=>"net_uuid",
                                                                                "show"=>"n",
                                                                               ),
                                                                    "20"=>array("name"=>"system_name", "head"=>__("System Name"),),
                                                                    "25"=>array("name"=>"system_description", "head"=>__("Description"),),
                                                                    "30"=>array("name"=>"net_user_name", "head"=>__("Current User"),),
                                                                    "40"=>array("name"=>"system_timestamp", "head"=>__("Date Audited"),),
                                                                    "50"=>array("name"=>"time_caption", "head"=>__("Time Zone"),),
                                                                    "60"=>array("name"=>"system_primary_owner_name", "head"=>__("Registered User"),),
                                                                    "70"=>array("name"=>"system_uuid", "head"=>__("UUID"),),
                                                                    "80"=>array("name"=>"system_model", "head"=>__("Model"),),
                                                                    "90"=>array("name"=>"system_id_number", "head"=>__("Serial"),),
                                                                    "100"=>array("name"=>"system_vendor", "head"=>__("Manufacturer"),),
                                                                    "110"=>array("name"=>"system_system_type", "head"=>__("Chassis Type"),),
                                                                   ),
                                                    ),
                                  "os"=>array(
                                                    "headline"=>__("Windows Information"),
                                                    "sql"=>"SELECT * FROM system WHERE system_uuid = '" . $pc . "' OR system_name = '" . $pc . "' ",
//                                                    "image"=>"images/o_os_windows.png",
                                                    "fields"=>array("10"=>array("name"=>"net_uuid",
                                                                                "show"=>"n",
                                                                               ),
                                                                    "15"=>array("name"=>"system_timestamp", "show"=>"n",),
                                                                    "20"=>array("name"=>"system_os_name", "head"=>__("Operating System"),),
                                                                    "30"=>array("name"=>"date_system_install", "head"=>__("OS Installed On"),),
                                                                    "40"=>array("name"=>"system_registered_user", "head"=>__("Registered User"),),
                                                                    "50"=>array("name"=>"system_organisation", "head"=>__("Registered Organisation"),),
                                                                    "60"=>array("name"=>"system_country_code", "head"=>__("Country Selected"),),
                                                                    "70"=>array("name"=>"system_language", "head"=>__("Language"),),
                                                                    "80"=>array("name"=>"system_serial_number", "head"=>__("Serial"),),
                                                                    "90"=>array("name"=>"system_service_pack", "head"=>__("Service Pack"),),
                                                                    "100"=>array("name"=>"system_windows_directory", "head"=>__("Windows Directory"),),
                                                                   ),
                                                    ),
                                  "network_card"=>array(
                                                    "headline"=>__("Network Settings"),
                                                    "sql"=>"SELECT * FROM system, network_card WHERE net_uuid = system_uuid AND net_uuid = '" . $pc . "' ",
//                                                    "image"=>"images/network_device_l.png",
                                                    "fields"=>array("30"=>array("name"=>"net_mac_address", "head"=>__("MAC Address"),),
                                                                    "40"=>array("name"=>"net_ip_address", "head"=>__("IP"),),
                                                                    "50"=>array("name"=>"net_ip_subnet", "head"=>__("Subnet"),),
                                                                    "60"=>array("name"=>"net_dhcp_enabled", "head"=>__("DHCP"),),
                                                                    "70"=>array("name"=>"net_dhcp_server", "head"=>__("DHCP Server"),),
                                                                    "80"=>array("name"=>"net_wins_primary", "head"=>__("Primary WINS"),),
                                                                    "90"=>array("name"=>"net_dns_server", "head"=>__("Primary DNS"),),
                                                                    "100"=>array("name"=>"net_manufacturer", "head"=>__("Manufacturer"),),
                                                                    "110"=>array("name"=>"net_description", "head"=>__("Description"),),
                                                                    "120"=>array("name"=>"net_domain_role", "head"=>__("Domain Role: "),),
                                                                    "130"=>array("name"=>"net_domain", "head"=>__("Domain"),),
                                                                    "140"=>array("name"=>"net_client_site_name", "head"=>__("Domain Site Name"),),
                                                                    "150"=>array("name"=>"net_domain_controller_name", "head"=>__("Domain Controller"),),

                                                                   ),
                                                    ),
                                  "bios"=>array(
                                                    "headline"=>__("Bios Settings"),
                                                    "sql"=>"SELECT * FROM system, bios WHERE bios_uuid = '" . $pc . "' AND bios_uuid = system_uuid AND system_timestamp = bios_timestamp ",
//                                                    "image"=>"images/bios_l.png",
                                                    "fields"=>array("10"=>array("name"=>"bios_manufacturer", "head"=>__("Bios Manufacturer"),),
                                                                    "20"=>array("name"=>"bios_version", "head"=>__("Bios Version"),),
                                                                   ),
                                                    ),
                                  "processor"=>array(
                                                    "headline"=>__("Processor"),
                                                    "sql"=>"SELECT * FROM system, processor WHERE processor_uuid = '" . $pc . "' AND processor_uuid = system_uuid AND processor_timestamp = system_timestamp ORDER BY processor_id",
//                                                    "image"=>"images/processor_l.png",
                                                    "fields"=>array("10"=>array("name"=>"processor_name", "head"=>__("Model"),),
                                                                    "20"=>array("name"=>"processor_max_clock_speed", "head"=>__("Max Speed Hz"),),
                                                                   ),
                                                    ),
                                  "memory"=>array(
                                                    "headline"=>__("Memory"),
                                                    "sql"=>"SELECT * FROM system WHERE system_uuid = '" . $pc . "' OR system_name = '" . $pc . "' ",
//                                                    "image"=>"images/memory_l.png",
                                                    "fields"=>array("10"=>array("name"=>"system_memory", "head"=>__("Memory"),),
                                                                   ),
                                                    ),
                                  "video"=>array(
                                                    "headline"=>__("Video Adapter"),
                                                    "sql"=>"SELECT * FROM system, video WHERE video_uuid = '" . $pc . "' AND video_uuid = system_uuid AND video_timestamp = system_timestamp ",
//                                                    "image"=>"images/video_l.png",
                                                    "fields"=>array("10"=>array("name"=>"video_caption", "head"=>__("Model"),),
                                                                    "20"=>array("name"=>"video_adapter_ram", "head"=>__("RAM"),),
                                                                    "30"=>array("name"=>"video_current_horizontal_res", "head"=>__("Horizontal Resolution (x)"),),
                                                                    "40"=>array("name"=>"video_current_vertical_res", "head"=>__("Vertical Resolution (y)"),),
                                                                    "50"=>array("name"=>"video_current_refresh_rate", "head"=>__("Refresh Rate"),),
                                                                    "60"=>array("name"=>"video_current_number_colours", "head"=>__("Color Depth"),),
                                                                   ),
                                                    ),
                                  "hard_drive"=>array(
                                                    "headline"=>__("Fixed Disks"),
                                                    "sql"=>"SELECT *
                                                            FROM hard_drive, system
                                                            WHERE hard_drive_uuid=system_uuid AND hard_drive_uuid = '" . $pc . "' AND  hard_drive_uuid = system_uuid AND hard_drive_timestamp = system_timestamp ORDER BY hard_drive_index",
//                                                    "image"=>"images/harddisk_l.png",
                                                    "fields"=>array("10"=>array("name"=>"hard_drive_index", "head"=>__("Index"),),
                                                                    "20"=>array("name"=>"hard_drive_interface_type", "head"=>__("Type"),),
                                                                    "30"=>array("name"=>"hard_drive_model", "head"=>__("Model"),),
                                                                    "40"=>array("name"=>"hard_drive_size", "head"=>__("Size"),),
                                                                   ),
                                                    ),
                                  "optical_drive"=>array(
                                                    "headline"=>__("Optical Drive"),
                                                    "sql"=>"SELECT * FROM optical_drive, system WHERE optical_drive_uuid = '" . $pc . "' AND optical_drive_uuid = system_uuid AND optical_drive_timestamp = system_timestamp ORDER BY optical_drive_drive",
//                                                    "image"=>"images/optical_l.png",
                                                    "fields"=>array("10"=>array("name"=>"optical_drive_drive", "head"=>__("Drive Letter"),),
                                                                    "20"=>array("name"=>"optical_drive_caption", "head"=>__("Manufacturer"),),
                                                                   ),
                                                    ),
                                  "sound"=>array(
                                                    "headline"=>__("Soundcard"),
                                                    "sql"=>"SELECT * FROM sound, system WHERE sound_uuid = '" . $pc . "' AND sound_uuid = system_uuid AND sound_timestamp = system_timestamp ",
//                                                    "image"=>"images/audio_l.png",
                                                    "fields"=>array("10"=>array("name"=>"sound_name", "head"=>__("Name"),),
                                                                    "20"=>array("name"=>"sound_manufacturer", "head"=>__("Manufacturer"),),
                                                                   ),
                                                    ),
                                  "keyboard"=>array(
                                                    "headline"=>__("Keyboard"),
                                                    "sql"=>"SELECT * FROM keyboard, system WHERE keyboard_uuid = '" . $pc . "' AND keyboard_uuid = system_uuid AND keyboard_timestamp = system_timestamp ",
//                                                    "image"=>"images/keyboard_l.png",
                                                    "fields"=>array("10"=>array("name"=>"keyboard_caption", "head"=>__("Type"),),
                                                                    "20"=>array("name"=>"keyboard_description", "head"=>__("Description"),),
                                                                   ),
                                                    ),
                                  "mouse"=>array(
                                                    "headline"=>__("Mouse"),
                                                    "sql"=>"SELECT * FROM mouse, system WHERE mouse_uuid = '" . $pc . "' AND mouse_uuid = system_uuid AND mouse_timestamp = system_timestamp ",
//                                                    "image"=>"images/mouse_l.png",
                                                    "fields"=>array("10"=>array("name"=>"mouse_description", "head"=>__("Description"),),
                                                                    "20"=>array("name"=>"mouse_number_of_buttons", "head"=>__("Buttons"),),
                                                                    "30"=>array("name"=>"mouse_port", "head"=>__("Port"),),
                                                                   ),
                                                    ),
                                 ),
                  );
?>
